#ifndef _PROTOCOL_HEAD_H__
#define _PROTOCOL_HEAD_H__
#include "head.h"


#define TEXT_MAX  128
#define  TYPE_LED     1
#define  TYPE_BUZZER  2
#define  TYPE_FAN     3

/*********M0 发送给 A9的消息**********/
#define  GOODS 'G'  //msg消息类型 ：货物
#define  ENV   'E'  //msg消息类型 : 环境


struct A_msg{
	int house_num:4;  //仓库编号
	int device_type:4; //设备类型
	int device_no:4;   //设备编号
	int operation:4;  //操作掩码
	int reserve:16;   //预留
};

struct env_msg{
	struct env_info m_env;
	int m_house_no;
	
};

struct good_msg{
	struct goods_info m_goods;
};

struct M_msg{
	char type;
	char text[TEXT_MAX];
	//char end;
};


#endif
